Skip to content

Optimize binary size with icon compression and build optimizations#13

Merged
bearice merged 1 commit intomasterfrom
feature/icon-compression-optimization
Jul 8, 2025
Merged

Optimize binary size with icon compression and build optimizations#13
bearice merged 1 commit intomasterfrom
feature/icon-compression-optimization

Conversation

@bearice
Copy link
Owner

@bearice bearice commented Jul 8, 2025

Summary

  • Compress all icons into single chunk using gzip for better compression
  • Add aggressive compiler optimizations for smaller release binaries
  • Refactor icon loading to decompress single chunk at runtime
  • Update app icon and preserve original as backup
  • Add flate2 dependency for compression support

Technical Details

The optimization changes include:

  • Icon Compression: All icon files are now compressed into a single gzip chunk during build, reducing binary size significantly
  • Build Optimizations: Added opt-level = "z", LTO, and other size-focused compiler flags
  • Runtime Decompression: Icons are decompressed once at startup and kept in memory for the lifetime of the application
  • Binary Size Reduction: Expect significant reduction in final executable size

Test plan

  • Build compiles successfully with new optimizations
  • Icon loading works correctly with compressed format
  • Application starts and displays tray icon properly
  • Theme switching between light/dark modes works
  • All icon animations function as expected

🤖 Generated with Claude Code

- Compress all icons into single chunk using gzip for better compression
- Add aggressive compiler optimizations for smaller release binaries
- Refactor icon loading to decompress single chunk at runtime
- Update app icon and preserve original as backup
- Add flate2 dependency for compression support

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
@bearice bearice merged commit 18ed2e3 into master Jul 8, 2025
2 checks passed
@bearice bearice deleted the feature/icon-compression-optimization branch July 8, 2025 05:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant